-- GENERATED SPELL FOR [Swiftwing Shredder] --


function spell0_20673(pUnit, Event) --@Lightning Breath,n/a--
pUnit:FullCastSpellOnTarget(36594,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20673', 3000, 1)
end

function spell1_20673(pUnit, Event) --@Lightning Shield,n/a--
pUnit:FullCastSpellOnTarget(19514,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20673', 0, 1)
end

function Sorts_20673(pUnit, Event)
local choix_sorts_20673 = math.random(0, 1)
if choix_sorts_20673 == 0 then
pUnit:RegisterEvent('spell0_20673', 1, 1)
end
if choix_sorts_20673 == 1 then
pUnit:RegisterEvent('spell1_20673', 1, 1)
end
end

function mob20673_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_20673', math.random(1500, 3000), 1)
end

function mob20673_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20673_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20673_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(20673, 1, 'mob20673_Action')
RegisterUnitEvent(20673, 2, 'mob20673_Leave')
RegisterUnitEvent(20673, 3, 'mob20673_Kill')
RegisterUnitEvent(20673, 4, 'mob20673_Die')
